{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "from sklearn import datasets"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "iris = datasets.load_iris()\n",
    "X = iris.data\n",
    "y = iris.target"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 34,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(150, 4)"
      ]
     },
     "execution_count": 34,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "X.shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(150,)"
      ]
     },
     "execution_count": 35,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "y.shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "X = X[y < 2, :2]\n",
    "y = y[y < 2]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 50,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAD8CAYAAACMwORRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4wLCBo\ndHRwOi8vbWF0cGxvdGxpYi5vcmcvpW3flQAAF8xJREFUeJzt3X+M3HWdx/Hn+5Y9XH/ABtmcsC1u\nDk3/EHqWbsCmifHAO1RqaZCTElBrOHpn5MBgMFdD1DQmxDRB5Uw0LeQA6QG9WnuFgBzKGYVAk1mK\n7R21CXhou+WOtbXFnntcu7zvj5ltd2dnd+YzM9+dz+czr0fSdOc7H759f75ffXc639f38zV3R0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n3ZcA/wP8fdWYlM9dI/NL+fwBUPm6aSXwz7XerrGtreevK5s75Yd+rzSzV4CHgEvN7IGpA9z9kLu/\nUXm5CVg6vyW2zt0PVn5/jfJ3fhdXDTkATP0XyQLg4PxU15p6c3P31939WOXnx4BeMzt73gttzgHg\ngLvvrLzeSrkZVo9J8tzRwPwSP3+TPgo87+7/XeO9ws9fVzZ3d1/n7gvcfYjyP5uecvfrp46p+v5r\nJeULr8kws7eZ2Tsmfwb+Evj3qmE7gE9Xrtx/ADjq7q/Oc6nBGpmbmb3LzKzy88WU/7d+aL5rbYa7\n/xew38wWVTZdBrxYNSzJcweNzS/l8zfFtdT+Sgbm4fx1e1pmGjNbD5TcfQdws5mtBE4Ah4E1nayt\nCX8C/LDy/4/TgH9y9x+Z2d8CuPv3gMeAjwEvAX8APtuhWkM1Mrergc+Z2QlgHFjtad2x93fA5so/\n7X8FfDaTczep3vySPn9m9lbgL4C/mbJtXs+f7lAVEclQV34tIyKSOzV3EZEMqbmLiGRIzV1EJENq\n7iIiGVJzFxHJkJq7iEiG1NxFRDL0/3wGhdBUbAVjAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x10b0697b8>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(X[y==0, 0], X[y==0, 1])\n",
    "plt.scatter(X[y==1, 0], X[y==1, 1])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 37,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(100, 2)"
      ]
     },
     "execution_count": 37,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "X.shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 38,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(100,)"
      ]
     },
     "execution_count": 38,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "y.shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 39,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "from sklearn.model_selection import train_test_split"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 40,
   "metadata": {},
   "outputs": [],
   "source": [
    "X_train, X_test, y_train, y_test = train_test_split(X, y, random_state=666)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 41,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "from LogisticRegression import LogisticRegression"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 42,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "LogisticRegression()"
      ]
     },
     "execution_count": 42,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg = LogisticRegression()\n",
    "log_reg.fit(X_train, y_train)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 43,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1.0"
      ]
     },
     "execution_count": 43,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg.score(X_test, y_test)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 44,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([ 0.93292947,  0.98717455,  0.15541379,  0.18370292,  0.03909442,\n",
       "        0.01972689,  0.05214631,  0.99683149,  0.98092348,  0.75469962,\n",
       "        0.0473811 ,  0.00362352,  0.27122595,  0.03909442,  0.84902103,\n",
       "        0.80627393,  0.83574223,  0.33477608,  0.06921637,  0.21582553,\n",
       "        0.0240109 ,  0.1836441 ,  0.98092348,  0.98947619,  0.08342411])"
      ]
     },
     "execution_count": 44,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg.predict_proba(X_test)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 45,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
       "       1, 0])"
      ]
     },
     "execution_count": 45,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "y_test"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 46,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1,\n",
       "       1, 0])"
      ]
     },
     "execution_count": 46,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg.predict(X_test)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 51,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "array([ 3.01749692, -5.03046934])"
      ]
     },
     "execution_count": 51,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg.coef_"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 52,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "-0.68273836989930958"
      ]
     },
     "execution_count": 52,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "log_reg.intercept_"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 53,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def x2(x1):\n",
    "    return (- log_reg.coef_[0] * x1 - log_reg.intercept_) / log_reg.coef_[1]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 54,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "x1_plot = np.linspace(4, 8, 1000)\n",
    "x2_plot = x2(x1_plot)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 56,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAD8CAYAAACMwORRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl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Ptn4l674zLGdDo+zmiMOQPv6/Kg\nlXGJyD5glzGmh2/RSMDlt1rEz1cwcdlxvvz8ipqHPiJ+zoKJy6ZzthM40xiT5Dv2SH6aCyzLYdFQ\nLfMjxphZwGoRWYB30ukVY0wu3ne7CQ6J61ZjzHjA7YtrcgRC6Ai843v9JgKvisgSY8yNACIyD1gM\nXALkAiXAdQ6J6wrgJmOMGygFJlj9Ju3zOyDL9+f8VuA6B5yvYOKy63xhjEkCLgB+e8Iy289ZEHFF\n/JyJyBfGmDfxDgm5ga+AzEjlMP2EqlJKxSDHDssopZSqP03uSikVgzS5K6VUDNLkrpRSMUiTu1JK\nxSBN7kopFYM0uSulVAzS5K6UUjHo/wMvwpxhYmAhhwAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x10b0694a8>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(X[y==0, 0], X[y==0, 1], color = 'r')\n",
    "plt.scatter(X[y==1, 0], X[y==1, 1], color= 'b')\n",
    "plt.plot(x1_plot, x2_plot)\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 58,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAD8CAYAAACMwORRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4wLCBo\ndHRwOi8vbWF0cGxvdGxpYi5vcmcvpW3flQAAIABJREFUeJzt3Xd4VGXe//H3nYQWpHcIIfQeFAKI\nKBYsoIgiuOJiL6joT3d9lCIWLKio665rXWwPKroqAaUoYMWGaFBJoZfQeyCBkJAy9++PCY8YEzKB\nmTlnZj6v68qVyTknM98chk/unHOf7zHWWkREJLxEOV2AiIj4n8JdRCQMKdxFRMKQwl1EJAwp3EVE\nwpDCXUQkDCncRUTCkM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+mSuu40xgwFikrqui4IJTQBZpW8f2OAd621840xtwJYa18B\nPgEuBNYCh4DrXVLXCOA2Y0wRkAeMDPQv6RL/D5he8uf8euB6F+wvX+pyan9hjIkFzgNuOWqZ4/vM\nh7qCvs+stUuMMTPwHhIqAn4FpgYrw3SFqohIGHLtYRkRETl+CncRkTCkcBcRCUMKdxGRMKRwFxEJ\nQwp3EZEwpHAXEQlDCncRkTD0/wEm3ntgOQ642AAAAABJRU5ErkJggg==\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x1a146fee10>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plt.scatter(X_test[y_test==0, 0], X_test[y_test==0, 1], color = 'r')\n",
    "plt.scatter(X_test[y_test==1, 0], X_test[y_test==1, 1], color= 'b')\n",
    "plt.plot(x1_plot, x2_plot)\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 61,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "def plot_decision_boundary(model, axis):\n",
    "    \n",
    "    x0, x1 = np.meshgrid(\n",
    "        np.linspace(axis[0], axis[1], int((axis[1] - axis[0]) * 100)).reshape(-1, 1),\n",
    "        np.linspace(axis[2], axis[3], int((axis[3] - axis[2]) * 100)).reshape(-1, 1)\n",
    "    )\n",
    "    X_new = np.c_[x0.ravel(), x1.ravel()]\n",
    "    \n",
    "    y_predict = model.predict(X_new)\n",
    "    zz = y_predict.reshape(x0.shape)\n",
    "    \n",
    "    from matplotlib.colors import ListedColormap\n",
    "    custom_cmap = ListedColormap(['#EF9A9A', '#FFF59D', '#90CAF9'])\n",
    "    \n",
    "    plt.contourf(x0, x1, zz, linewidth=5, cmap=custom_cmap)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/Users/Winter/anaconda3/lib/python3.6/site-packages/matplotlib/contour.py:967: UserWarning: The following kwargs were not used by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FpjUHgLMBIuIk4PmUZzpnx/oz85HMPNp4+nng3NGWuLzM\n/E3jvw8xvwd4ftOSE+e/YS3zQ/DGrlPtJR/rcQA4kJl7G893MR+gzWtKee4pUH/Jz/+C1wP3ZObv\nWrxW5vO/oG39vZz/oQZ+Zl6XmWszcx3zv5Z8NzPf1LRsD7C18fiqxppS/CtbpP6mPb9NzH+4WwoR\n8dyIOGXhMfDnQPOE0j3AWxodC68GHsvMB0dc6rMUqT1KPNYjM38LPBARC5MNLwV+2bSslOceitVf\n5vO/yF/QfjuktOd/kbb193L+R9Wls0RE3ADMZuYe5j8U2hkR+5m/st88jpq60VT/eyJiE3Cc+fqv\nGWdtTV4M7G78P3ES8M+ZeUdEvANOjMb4FnAZsB94EnjrmGptVqT2Xsd6jMpfAbc2fi3/H+CtFTn3\nCzrVX+rzHxEnA38G/OWiY5U5/wXq7/r8O1pBkmrCO20lqSYMfEmqCQNfkmrCwJekmjDwJakmDHxJ\nqgkDX5Jq4v8BAu6qkkr228cAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x10b0bd5f8>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plot_decision_boundary(log_reg, axis = [4, 7.5, 1.5, 4.5])\n",
    "plt.scatter(X_test[y_test==0, 0], X_test[y_test==0, 1], color = 'r')\n",
    "plt.scatter(X_test[y_test==1, 0], X_test[y_test==1, 1], color= 'b')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 63,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "KNeighborsClassifier(algorithm='auto', leaf_size=30, metric='minkowski',\n",
       "           metric_params=None, n_jobs=1, n_neighbors=5, p=2,\n",
       "           weights='uniform')"
      ]
     },
     "execution_count": 63,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "from sklearn.neighbors import KNeighborsClassifier\n",
    "knn_clf = KNeighborsClassifier()\n",
    "knn_clf.fit(X_train, y_train)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 64,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "1.0"
      ]
     },
     "execution_count": 64,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "knn_clf.score(X_test, y_test)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 67,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/Users/Winter/anaconda3/lib/python3.6/site-packages/matplotlib/contour.py:967: UserWarning: The following kwargs were not used by contour: 'linewidth'\n",
      "  s)\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXwAAAD8CAYAAAB0IB+mAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMS4wLCBo\ndHRwOi8vbWF0cGxvdGxpYi5vcmcvpW3flQAAEflJREFUeJzt3W2spGV9x/Hvr8sWUBc3sKYQFt00\nEF9oFHCDGhJCwTaKZHkhxm1QwWi2Gq1gNKZoQiPveGNFbTQrtF3UWiw+dCVgqlFSSQpmWRcU15pt\nq9lVWp7kYavSrv774syuZ4c5OzPnzMN9n/v7SU525r6vM/xzh/zONf+57mtSVUiSVr/fm3cBkqTZ\nMPAlqSMMfEnqCANfkjrCwJekjjDwJakjRg78JGuSfC/J7QPOXZXkkSR7ej/vmGyZkqSVOm6MsVcD\ne4GTljh/a1W9Z+UlSZKmYaQZfpKNwOuBm6ZbjiRpWkad4X8M+CCw7hhj3pDkAuDHwPuqan//gCTb\ngG0Azz3++FecdeqpY5YrSQseO/GUeZcwF/t/tPvRqnrBcn53aOAnuRR4uKruS3LhEsO+Bnyhqp5J\n8k5gB3BR/6Cq2g5sBzhn06b69oc/vJyaJXXU+ivWcOODb553GXN1zXnH/3S5vzvKDP98YEuSS4AT\ngJOSfK6qjlz1qnps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+qrq2qjVW1iYW3Jd+qqjf3DdsJXNl7fHlvTCP+yo5Sf1/PbwsL\nH+42QpLnJll3+DHwJ0D/DqU7gbf2Viy8Cniyqh6acanPMkrtafC2HlX1X8D+JId3NrwY+GHfsEZe\nexit/iZf/0X+lKXbIY29/ossWf9yrv+sVukcJcn1wK6q2snCh0KfTbKPhZn91nnUNI6++t+bZAtw\niIX6r5pnbX3+APhK7/+J44C/r6qvJ3knHNka4w7gEmAf8EvgbXOqtd8otS93W49Z+XPg87235f8B\nvK0l1/6wYfU3+voneQ7wx8CfLTrWmus/Qv1jX3+3VpCkjvBOW0nqCANfkjrCwJekjjDwJakjDHxJ\n6ggDX5I6wsCXpI74fyYUEek4UN2uAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x10ae2b438>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plot_decision_boundary(knn_clf, axis=[4, 7.5, 1.5, 4.5])\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 68,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "KNeighborsClassifier(algorithm='auto', leaf_size=30, metric='minkowski',\n",
       "           metric_params=None, n_jobs=1, n_neighbors=5, p=2,\n",
       "           weights='uniform')"
      ]
     },
     "execution_count": 68,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "knn_clf_all = KNeighborsClassifier()\n",
    "knn_clf_all.fit(iris.data[:, :2], iris.target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 71,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/Users/Winter/anaconda3/lib/python3.6/site-packages/matplotlib/contour.py:967: UserWarning: The following kwargs were not used by contour: 'linewidth'\n",
      "  s)\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXwAAAD8CAYAAAB0IB+mAAAABHNCSVQICAgIfAhkiA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IhcD8OtLjYDlwI7gX7gSzGNs9aWHEG6Cegq/Hm/C/hSDK+llzjjcC0RkYnAfwX+tGRZ7K6nhzgj\nv56q2i0iT5KfXjoK/ALo9Js7rbWCMcakhD1pa4wxKWEJ3xhjUsISvjHGpIQlfGOMSQlL+MYYkxKW\n8I0xJiUs4RtjTEr8fxun7UM6hqNsAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x1a145e36a0>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plot_decision_boundary(knn_clf_all, axis=[4, 8, 1.5, 4.5])\n",
    "plt.scatter(iris.data[iris.target==0, 0], iris.data[iris.target==0, 1], color = 'r')\n",
    "plt.scatter(iris.data[iris.target==1, 0], iris.data[iris.target==1, 1], color= 'b')\n",
    "plt.scatter(iris.data[iris.target==2, 0], iris.data[iris.target==2, 1], color= 'g')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 72,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "KNeighborsClassifier(algorithm='auto', leaf_size=30, metric='minkowski',\n",
       "           metric_params=None, n_jobs=1, n_neighbors=50, p=2,\n",
       "           weights='uniform')"
      ]
     },
     "execution_count": 72,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "knn_clf_all = KNeighborsClassifier(n_neighbors=50)\n",
    "knn_clf_all.fit(iris.data[:, :2], iris.target)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 73,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/Users/Winter/anaconda3/lib/python3.6/site-packages/matplotlib/contour.py:967: UserWarning: The following kwargs were not used by contour: 'linewidth'\n",
      "  s)\n"
     ]
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXwAAAD8CAYAAAB0IB+mAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AA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8GrBaqEfSzdxhn0sC1xN6dMkoR/PUUrGGZHjuRs4R0QacrFcxPicU3buDKpKZwwRuQvoUdUn\nyV6M2iAiO8j+dLoqjJiKKYjz6yJyOXCEbJzXhhDSCcDm3L/FY4D/papPichyGGl1sQW4BNgBDABf\njmiclbbk8NP1wMbcr/c7gS9H8Fi6iTMKxxIRaQD+E/BfRo1F7ni6iDP046mq3SLyBNnTS0eA3wFd\nXnOntVYwxpiEsDttjTEmISzhG2NMQljCN8aYhLCEb4wxCWEJ3xhjEsISvjHGJIQlfGOMSYj/D1/5\nmpdpYTVqAAAAAElFTkSuQmCC\n",
      "text/plain": [
       "<matplotlib.figure.Figure at 0x1a152e6518>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "plot_decision_boundary(knn_clf_all, axis=[4, 8, 1.5, 4.5])\n",
    "plt.scatter(iris.data[iris.target==0, 0], iris.data[iris.target==0, 1], color = 'r')\n",
    "plt.scatter(iris.data[iris.target==1, 0], iris.data[iris.target==1, 1], color= 'b')\n",
    "plt.scatter(iris.data[iris.target==2, 0], iris.data[iris.target==2, 1], color= 'g')\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
